package com.doubao.chat;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.FilterType;

/**
 * 豆包AI聊天服务启动类
 */
@SpringBootApplication
@EnableDiscoveryClient
@EnableFeignClients(basePackages = {"com.doubao.chat.client", "com.doubao.user.client"})
@ComponentScan(basePackages = {
    "com.doubao.chat", 
    "com.doubao.common", 
    "com.doubao.device",
    "com.doubao.user.service",
    "com.doubao.user.entity",
    "com.doubao.user.mapper",
    "com.doubao.user.security"
}, excludeFilters = {
    @ComponentScan.Filter(type = FilterType.ASSIGNABLE_TYPE, classes = {com.doubao.user.config.FeignConfig.class})
})
@MapperScan(basePackages = {"com.doubao.chat.mapper"})
public class DoubaoChatApplication {
    public static void main(String[] args) {
        SpringApplication.run(DoubaoChatApplication.class, args);
    }
}
